package com.neusoft.pojo;

import java.util.Date;

public class Emp {

    private String ename;
    private int empno;
    private String job;
    private Date hiredate;

    //主表的对象当成从表的属性
    private Dept dept;

    public Dept getDept() {
        return dept;
    }

    public void setDept(Dept dept) {
        this.dept = dept;
    }

    public String getEname() {
        return ename;
    }

    public void setEname(String ename) {
        this.ename = ename;
    }

    public int getEmpno() {
        return empno;
    }

    public void setEmpno(int empno) {
        this.empno = empno;
    }

    public String getJob() {
        return job;
    }

    public void setJob(String job) {
        this.job = job;
    }

    public Date getHiredate() {
        return hiredate;
    }

    public void setHiredate(Date hiredate) {
        this.hiredate = hiredate;
    }

    public Emp(String ename, int empno, String job, Date hiredate) {
        this.ename = ename;
        this.empno = empno;
        this.job = job;
        this.hiredate = hiredate;
    }

    public Emp() {
    }

    @Override
    public String toString() {
        return "Emp{" +
                "ename='" + ename + '\'' +
                ", empno=" + empno +
                ", job='" + job + '\'' +
                ", hiredate=" + hiredate +
                '}';
    }
}
